<div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <h5>查询条件</h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-link btn-sm" style="margin-right:10px;"
                                v-on:click="_moreCondition()">
                            {{allocationUserStorehouseManageInfo.moreCondition == true?'隐藏':'更多'}}
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <div class="row">
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" placeholder="请输入物品资源ID"
                                       v-model="allocationUserStorehouseManageInfo.conditions.resId"
                                       class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-4">
                            <div class="form-group">
                                <input type="text" placeholder="请输入物品名称"
                                       v-model="allocationUserStorehouseManageInfo.conditions.resName"
                                       class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" placeholder="请输入接受人ID"
                                       v-model="allocationUserStorehouseManageInfo.conditions.acceptUserId"
                                       class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-2">
                            <button type="button" class="btn btn-primary btn-sm"
                                    v-on:click="_queryAllocationUserStorehouseMethod()">
                                <i class="fa fa-search"></i> 查询
                            </button>
                            <button type="button" class="btn btn-primary btn-sm"
                                    v-on:click="_resetAllocationUserStorehouseMethod()">
                                <i class="fa fa-repeat"></i> 重置
                            </button>
                        </div>
                    </div>
                    <div class="row" v-show="allocationUserStorehouseManageInfo.moreCondition == true">
                        <div class="col-sm-3">
                            <div class="form-group">
                                <select class="custom-select" v-model="allocationUserStorehouseManageInfo.conditions.parentRstId" @change="_listResourceStoreSonTypes">
                                    <option selected value="">请选择物品类型</option>
                                    <option v-for="(item,index) in allocationUserStorehouseManageInfo.resourceStoreTypes"
                                            :key="index" v-bind:value="item.rstId">
                                        {{item.name}}
                                    </option>
                                </select>
                            </div>
                        </div>
                        <div class="col-sm-4">
                            <div class="input-group">
                                <select class="custom-select" v-model="allocationUserStorehouseManageInfo.conditions.rstId" @change="_listResourceStoreSpecifications">
                                    <option selected value="">请选择二级分类</option>
                                    <option v-for="(item,index) in allocationUserStorehouseManageInfo.resourceStoreSonTypes" :key="index"
                                        v-bind:value="item.rstId">
                                        {{item.name}}
                                    </option>
                                </select>
                            </div>
                        </div>
                        <div class="col-sm-3">
                            <div class="form-group">
                                <select class="custom-select"
                                        v-model="allocationUserStorehouseManageInfo.conditions.rssId">
                                    <option selected value="">请选择物品规格</option>
                                    <option v-for="(item,index) in allocationUserStorehouseManageInfo.resourceStoreSpecifications"
                                            :key="index" v-bind:value="item.rssId">
                                        {{item.specName}}
                                    </option>
                                </select>
                            </div>
                        </div>
                    </div>
                    <div class="row" v-show="allocationUserStorehouseManageInfo.moreCondition == true">
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" placeholder="请输入接受人名称"
                                       v-model="allocationUserStorehouseManageInfo.conditions.acceptUserName"
                                       class=" form-control">
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox">
                <div class="ibox-title">
                    <h5>转赠记录信息</h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-primary btn-sm" v-on:click="_exportExcel()">
                            <i class="fa fa-plus"></i>导出
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <table class="footable table table-stripped toggle-arrow-tiny"
                           data-page-size="15">
                        <thead>
                        <tr>
                            <th class="text-center">转赠记录编号</th>
                            <th class="text-center">物品资源ID</th>
                            <th class="text-center">物品类型</th>
                            <th class="text-center">物品名称</th>
                            <th class="text-center">物品规格</th>
                            <th class="text-center">是否是固定物品</th>
                            <th class="text-center">转赠人ID</th>
                            <th class="text-center">转赠人</th>
                            <th class="text-center">转赠对象ID</th>
                            <th class="text-center">转赠对象</th>
                            <th class="text-center">原有库存</th>
                            <th class="text-center">转赠数量</th>
                            <th class="text-center">创建时间</th>
                            <th class="text-center">备注</th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr v-for="allocationUserStorehouse in allocationUserStorehouseManageInfo.allocationUserStorehouses">
                            <td class="text-center">{{allocationUserStorehouse.ausId}}</td>
                            <td class="text-center">{{allocationUserStorehouse.resId}}</td>
                            <td class="text-center">
                                {{allocationUserStorehouse.parentRstName}} > {{allocationUserStorehouse.rstName}}
                            </td>
                            <td class="text-center">{{allocationUserStorehouse.resName}}</td>
                            <td class="text-center">
                                {{allocationUserStorehouse.specName ? allocationUserStorehouse.specName : '-'}}
                            </td>
                            <td class="text-center">{{allocationUserStorehouse.isFixedName}}</td>
                            <td class="text-center">{{allocationUserStorehouse.startUserId}}</td>
                            <td class="text-center">{{allocationUserStorehouse.startUserName}}</td>
                            <td class="text-center">{{allocationUserStorehouse.acceptUserId}}</td>
                            <td class="text-center">{{allocationUserStorehouse.acceptUserName}}</td>
                            <td class="text-center">{{allocationUserStorehouse.stock}}{{allocationUserStorehouse.unitCodeName}}</td>
                            <td class="text-center">{{allocationUserStorehouse.giveQuantity}}{{allocationUserStorehouse.miniUnitCodeName}}</td>
                            <td class="text-center">{{allocationUserStorehouse.createTime}}</td>
                            <td class="text-center">{{allocationUserStorehouse.remark}}</td>
                        </tr>
                        </tbody>
                        <tfoot>
                        <tr>
                            <td colspan="14">
                                <ul class="pagination float-right"></ul>
                            </td>
                        </tr>
                        </tfoot>
                    </table>
                    <!-- 分页 -->
                    <div class="row">
                        <div class="col-md-6 text-left">
                            <span class="margin-left"><span class="col-md-1"><b>小计</b></span>
                                <span class="col-md-1 margin-left">转赠总数量：{{allocationUserStorehouseManageInfo.subTotalQuantity}}</span>
                            </span>
                            <br/>
                            <span class="margin-left"><span class="col-md-1"><b>大计</b></span>
                                <span class="col-md-1 margin-left">转赠总数量：{{allocationUserStorehouseManageInfo.highTotalQuantity}}</span>
                            </span>
                        </div>
                        <div class="col-md-6 text-right">
                            <vc:create path="frame/pagination"></vc:create>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
